Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial support for chunmi.cooker.eh1 #1018

Merged
merged 4 commits into from
May 4, 2024
Merged

Conversation

sschirr
Copy link
Contributor

@sschirr sschirr commented Apr 14, 2021

This provides basic support for the Xiaomi Mi Smart MultiCooker.

This is supported:

  • Start/Set a recipe profile
    • With support for duration, schedule and autokeepwarm (akw)
  • Get some status information including:
    • operation mode
    • menu
    • cooking stage (incomplete)
    • temperature + history
    • cooking times

This is not supported:

  • any other change to cooking profiles except: duration, schedule, akw
    • like: rice type, taste setting, temperature curve etc...
  • cooker settings
  • factory reset
  • firmware version
  • ...

@syssi
Copy link
Collaborator

syssi commented Apr 14, 2021

Your implementation is pretty advanced especially the custom cooking profiles. Could you provide some tests or test data (of different cooking stages) to be able to implement some tests later on?

@FaserF
Copy link

FaserF commented Jul 15, 2021

I am using the fork from sschirr and can say that everything works fine so far with my chunmi.cooker.eh1

@sschirr sschirr force-pushed the master branch 3 times, most recently from 4bfc7d8 to ce2855e Compare July 20, 2021 20:38
@blakadder
Copy link

I'm also using the forked version, cooker works without issues

@sschirr
Copy link
Contributor Author

sschirr commented Jan 18, 2024

Is there any change to get this merged?
Its been a long time since I implemented it and I am happy to solve the branch conflicts if there is still interest.

Copy link
Owner

@rytilahti rytilahti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @sschirr and thanks for the PR. My sincerest apologies that I have somehow managed to ignore this... I added some comments inline, but for most of the parts this seems to be quite ready, and we should make it into the 0.6.0 release.

miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
miio/cooker_multi.py Outdated Show resolved Hide resolved
Copy link

codecov bot commented Mar 30, 2024

Codecov Report

Attention: Patch coverage is 83.92157% with 41 lines in your changes missing coverage. Please review.

Project coverage is 81.45%. Comparing base (8643a57) to head (249265a).
Report is 4 commits behind head on master.

Files with missing lines Patch % Lines
...o/integrations/chunmi/cooker_multi/cooker_multi.py 77.71% 31 Missing and 10 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1018      +/-   ##
==========================================
+ Coverage   81.41%   81.45%   +0.03%     
==========================================
  Files         193      196       +3     
  Lines       18636    18891     +255     
  Branches     4045     4111      +66     
==========================================
+ Hits        15173    15387     +214     
- Misses       3180     3211      +31     
- Partials      283      293      +10     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sschirr
Copy link
Contributor Author

sschirr commented Mar 30, 2024

Thanks for reviewing the changes!

Right now I am not able to do tests with a real device but I might be able to in the next days.
If someone tries the new changes please leave some feedback :)

Copy link
Owner

@rytilahti rytilahti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of more minor things I noticed, otherwise this seems good to go from my side, but please give it a proper testing on a real device :-)

miio/integrations/chunmi/cooker_multi/cooker_multi.py Outdated Show resolved Hide resolved
pyproject.toml Outdated Show resolved Hide resolved
@sschirr
Copy link
Contributor Author

sschirr commented May 3, 2024

I tested the changes with my fork of the xiaomi_cooker HA component (xiaomi_cooker) again with a real device. It looks good to me.

@sschirr sschirr requested a review from rytilahti May 3, 2024 21:02
Copy link
Owner

@rytilahti rytilahti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I moved the import of crcmod inside the checksum calculation & run poetry update to fix the CI. This looks ready to go for me, I'll merge this as soon as the CI finishes, thanks @sschirr! 👍

@rytilahti rytilahti merged commit 204f19d into rytilahti:master May 4, 2024
22 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants